home *** CD-ROM | disk | FTP | other *** search
/ Mac Magazin/MacEasy 19 / Mac Magazin and MacEasy Magazine CD - Issue 19.iso / Grafik & Text & Film / Quark XTensions / Freeware Xtensions / XPress Scripts 1.0 / Delete Guides / Delete Guides next >
Text File  |  1994-08-10  |  887b  |  34 lines

  1. tell application "QuarkXPress 3.3"
  2.     activate
  3.     if document 1 exists then
  4.         tell document 1
  5.             copy name to docName
  6.             copy (display dialog "Delete all guides in:" & return & "'" & docName & "'?" with icon 2000) to x
  7.             do updates
  8.             if button returned of x is "OK" then
  9.                 tell every spread
  10.                     if every vertical guide exists then
  11.                         delete every vertical guide
  12.                     end if
  13.                     if every horizontal guide exists then
  14.                         delete every horizontal guide
  15.                     end if
  16.                 end tell
  17.                 
  18.                 tell every page
  19.                     if every vertical guide exists then
  20.                         delete every vertical guide
  21.                     end if
  22.                     if every horizontal guide exists then
  23.                         delete every horizontal guide
  24.                     end if
  25.                 end tell
  26.             end if
  27.         end tell
  28.     else
  29.         beep
  30.         display dialog "This script requires an" & return & "open QuarkXPress document." buttons "OK" default button 1 with icon 1
  31.         do updates
  32.     end if
  33. end tell
  34.